package com.yq.cp.mapper.basics;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yq.cp.entity.basics.EquipmentManagement;
import com.yq.cp.entity.common.PageVo;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;

import java.math.BigDecimal;

/**
 * <p>
 * 设备管理 Mapper 接口
 * </p>
 *
 * @author shenyuqing
 * @since 2024-08-27
 */
public interface EquipmentManagementMapper extends BaseMapper<EquipmentManagement> {

    Page<EquipmentManagement> examineList(@Param("page") Page<EquipmentManagement> page, @Param("vo")PageVo vo);

    Page<EquipmentManagement> removeExamineList(@Param("page") Page<EquipmentManagement> page, @Param("vo")PageVo vo);
    @Update("UPDATE t_equipment_management SET delete_examine = NULL WHERE id = #{id}")
    void bohui(@Param("id") Long id);

    @Update("UPDATE t_equipment_management SET yxzt=#{yxzt} WHERE id=#{id}")
    Long xgyxzt(@Param("id") Long id,@Param("yxzt") Integer yxzt);
    @Update("UPDATE t_equipment_management SET yxxl=#{yxxl} WHERE id=#{id}")
    Long xgyxxl(@Param("id") Long id,@Param("yxxl") BigDecimal yxxl);
    @Update("UPDATE t_equipment_management SET yxgl=#{yxgl} WHERE id=#{id}")
    Long xgyxgl(@Param("id") Long id,@Param("yxgl") BigDecimal yxgl);

    IPage<EquipmentManagement> deleteToRemove(@Param("page")IPage<EquipmentManagement> page, @Param("vo")PageVo vo);
}
